from api.ihrm_dept_api import IHRMDeptManageApi
from common.token_util import TokenUtil


class DeptUtil:
    @classmethod
    def get_dept_id(cls):
        token = TokenUtil.get_token()
        body = {"name":"测试01","code":"1234567"}
        resp = IHRMDeptManageApi.add_dept_api(token , body)
        dep_id = resp.json().get("data").get("id")
        return dep_id


